package com.exam.service;

import com.exam.entity.User;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;

public interface UserService {
    User createUser(User user); // 创建用户

    User updateUser(Long id, User user); // 更新用户

    void deleteUser(Long id); // 删除用户

    User getUserById(Long id); // 查询单个用户

    Page<User> getAllUsers(Pageable pageable); // 分页查询用户

    User login(String username, String password); // 登录
}